This repository was archived by the owner on Apr 12, 2024. It is now read-only.
perf($compile): remove use of deepEquals and $stateful interceptor from bidi bindings #16550
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
What kind of change does this PR introduce? (Bug fix, feature, docs update, ...)
performance, bug fixes (the two
my-component reference
tests previously failed)What is the current behavior? (You can also link to an open issue here)
$stateful
interceptor. This means the full expression is executed on every digest due to no input-watching.$stateful
interceptorWhat is the new behavior (if this is a feature change)?
No more
$stateful
interceptors or deep watching when using bidi directive/component inputs.Does this PR introduce a breaking change?
Maybe? But no tests required changing (other then the watcher counts). I thought removing the use of deep equals on literals might change something but I'm not 100% sure...
I guess it might reduce the number of times a literal is evaluated and therefore copy a new instance into the
destination
less frequently. If someone was modifying the internals of the object, those modifications will now be overridden less often? Or maybe previously they would get anoassign
error because the deepEquals detected that change, and now thesimpleCompare
won't detect it at all...